ruleWithConfiguration(RenameAttributeRector::class, [new RenameAttribute('Symfony\\Component\\DependencyInjection\\Attribute\\MapDecorated', 'Symfony\\Component\\DependencyInjection\\Attribute\\AutowireDecorated')]); $rectorConfig->ruleWithConfiguration(RenameClassRector::class, [ // @see https://github.com/symfony/symfony/blob/7.0/UPGRADE-7.0.md#frameworkbundle 'Symfony\\Component\\Serializer\\Normalizer\\ObjectNormalizer' => 'Symfony\\Component\\Serializer\\Normalizer\\NormalizerInterface', 'Symfony\\Component\\Serializer\\Normalizer\\PropertyNormalizer' => 'Symfony\\Component\\Serializer\\Normalizer\\NormalizerInterface', // @see https://github.com/symfony/symfony/blob/7.0/UPGRADE-7.0.md#httpfoundation 'Symfony\\Component\\HttpFoundation\\RequestMatcher' => 'Symfony\\Component\\HttpFoundation\\ChainRequestMatcher', 'Symfony\\Component\\HttpFoundation\\ExpressionRequestMatcher' => 'Symfony\\Component\\HttpFoundation\\RequestMatcher\\ExpressionRequestMatcher', ]); // @see https://github.com/symfony/symfony/pull/50826 $rectorConfig->ruleWithConfiguration(RenameMethodRector::class, [new MethodCallRename('Symfony\\Component\\HttpFoundation\\Request', 'getContentType', 'getContentTypeFormat')]); // the "@required" was dropped, use attribute instead $rectorConfig->ruleWithConfiguration(AnnotationToAttributeRector::class, [new AnnotationToAttribute('required', 'Symfony\\Contracts\\Service\\Attribute\\Required')]); };